﻿using System;

namespace CardPlay.Model.CardModel
{
    public static class DealExpression
    {
        public const string Remaining = "remaining";
        public const string Up = "up";
        public const string Down = "down";

        public static string ForOrientation(CardOrientation orientation)
        {
            return orientation == CardOrientation.FaceUp ? Up : Down;
        }

        public static string ForRemainingCards(CardOrientation orientation, int atStep = 20)
        {
            return new String(';', atStep) + Remaining + " " + ForOrientation(orientation);
        }

        public static string ForCard(Suit suit, Rank rank, CardOrientation orientation)
        {
            return String.Format("face({0} {1}) {2}", suit, rank, ForOrientation(orientation)).ToLower();
        }
    }
}